﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace CPPEI.Coolzon.UI.ValueEditors
{
    public static class ValueEditorFactory
    {
        public static ValueEditor Create(string valueType)
        {
            ValueEditor ve;
            switch (valueType.ToLower())
            {
                case "string": ve = new StringEditor(); break;
                case "month": ve = new MonthEditor(); break;
                case "datetime": ve = new DateTimeEditor(); break;
                case "int": ve = new IntegerEditor(); break;
                default: ve = new ValueEditor(); break;
            }
            return ve;
        }
    }
}
